package com.wms.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.github.pagehelper.Page;
import com.github.pagehelper.PageHelper;
import com.wms.dto.ConfirmCountDto;
import com.wms.mapper.WarehousingEntryDetailsSortMapper;
import com.wms.pojo.PageResult;
import com.wms.pojo.WarehousingEntryDetailsSort;
import com.wms.service.WarehousingEntryDetailsSortService;
import com.wms.vo.WarehousingSortVo;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class WarehousingEntryDetailsSortServiceImpl extends ServiceImpl<WarehousingEntryDetailsSortMapper, WarehousingEntryDetailsSort> implements WarehousingEntryDetailsSortService {


    @Override
    public PageResult queryPage(Integer page, Integer pageSize, String supplierName) {
        PageHelper.startPage(page,pageSize);
        List<WarehousingSortVo> voList = getBaseMapper().queryPage(supplierName);
        Page<WarehousingSortVo> list = (Page<WarehousingSortVo>) voList;
        return new PageResult(list.getTotal(),list.getResult());
    }

}
    